
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

<HTML>

<HEAD>
   <TITLE>dvdot_c</TITLE>
</HEAD>

<BODY style="color: rgb(0, 0, 0); background-color: rgb(255, 255, 255);">
<A name="TOP"></A>

<table style="text-align: left; margin-left: auto; margin-right: auto; width: 800px;"
 border="0" cellpadding="5" cellspacing="2">
  <tbody>
    <tr>
      <td style="background-color: rgb(153, 153, 153); vertical-align: middle; text-align: center;">
      <div align="right"> 
      <small><small><a href="index.html">Index Page</a></small></small>
      </div>
      <b>dvdot_c</b> </td>
    </tr>

    <tr>
      <td style="vertical-align: top;">

<small><div align="center">
<A HREF="index.html#A">A</A>&nbsp;
<A HREF="index.html#B">B</A>&nbsp;
<A HREF="index.html#C">C</A>&nbsp;
<A HREF="index.html#D">D</A>&nbsp;
<A HREF="index.html#E">E</A>&nbsp;
<A HREF="index.html#F">F</A>&nbsp;
<A HREF="index.html#G">G</A>&nbsp;
<A HREF="index.html#H">H</A>&nbsp;
<A HREF="index.html#I">I</A>&nbsp;
<A HREF="index.html#J">J</A>&nbsp;
<A HREF="index.html#K">K</A>&nbsp;
<A HREF="index.html#L">L</A>&nbsp;
<A HREF="index.html#M">M</A>&nbsp;
<A HREF="index.html#N">N</A>&nbsp;
<A HREF="index.html#O">O</A>&nbsp;
<A HREF="index.html#P">P</A>&nbsp;
<A HREF="index.html#Q">Q</A>&nbsp;
<A HREF="index.html#R">R</A>&nbsp;
<A HREF="index.html#S">S</A>&nbsp;
<A HREF="index.html#T">T</A>&nbsp;
<A HREF="index.html#U">U</A>&nbsp;
<A HREF="index.html#V">V</A>&nbsp;
<A HREF="index.html#W">W</A>&nbsp;
<A HREF="index.html#X">X</A>&nbsp;
</div></small>
       <br>
       <table style="text-align: left; width: 60%; margin-left: auto; margin-right: auto;"
       border="0" cellspacing="2" cellpadding="2">
        <tbody>
          <tr>
            <td style="width: 50%; text-align: center;">
            <small>
              <a href="#Procedure">Procedure<br></a>
              <a href="#Abstract">Abstract<br></a>
              <a href="#Required_Reading">Required_Reading<br></a>
              <a href="#Keywords">Keywords<br></a>
              <a href="#Brief_I/O">Brief_I/O<br></a>
              <a href="#Detailed_Input">Detailed_Input<br></a>

              </small>
              </td>
              <td style="vertical-align: top; width: 50%; text-align: center;">
              <small>               <a href="#Detailed_Output">Detailed_Output<br></a>
              <a href="#Parameters">Parameters<br></a>
              <a href="#Exceptions">Exceptions<br></a>
              <a href="#Files">Files<br></a>
              <a href="#Particulars">Particulars<br></a>
              <a href="#Examples">Examples<br></a>

              </small>
              </td>
              <td style="vertical-align: top; width: 50%; text-align: center;">
              <small>               <a href="#Restrictions">Restrictions<br></a>
              <a href="#Literature_References">Literature_References<br></a>
              <a href="#Author_and_Institution">Author_and_Institution<br></a>
              <a href="#Version">Version<br></a>
              <a href="#Index_Entries">Index_Entries<br></a>
             </small>
            </td>
          </tr>
        </tbody>
</table>

<h4><a name="Procedure">Procedure</a></h4>
<PRE>
   SpiceDouble dvdot_c ( ConstSpiceDouble s1[6],
                         ConstSpiceDouble s2[6] )

</PRE>
<h4><a name="Abstract">Abstract</a></h4>
<PRE>
   Compute the derivative of the dot product of two double
   precision position vectors.
</PRE>
<h4><a name="Required_Reading">Required_Reading</a></h4>
<PRE>
   None.
</PRE>
<h4><a name="Keywords">Keywords</a></h4>
<PRE>
   VECTOR
   DERIVATIVE


</PRE>
<h4><a name="Brief_I/O">Brief_I/O</a></h4>
<PRE>
   VARIABLE  I/O  DESCRIPTION
   --------  ---  --------------------------------------------------
   s1         I   First state vector in the dot product.
   s2         I   Second state vector in the dot product.

   The function returns the derivative of the dot product &lt;s1,s2&gt;
</PRE>
<h4><a name="Detailed_Input">Detailed_Input</a></h4>
<PRE>
   s1      Any state vector.  The components are in order
           (x, y, z, dx/dt, dy/dt, dz/dt )

   s2      Any state vector.
</PRE>
<h4><a name="Detailed_Output">Detailed_Output</a></h4>
<PRE>
   The function returns the derivative of the dot product of the
   position portions of the two state vectors s1 and s2.
</PRE>
<h4><a name="Parameters">Parameters</a></h4>
<PRE>
   None.
</PRE>
<h4><a name="Exceptions">Exceptions</a></h4>
<PRE>
   Error free.
</PRE>
<h4><a name="Files">Files</a></h4>
<PRE>
   None.
</PRE>
<h4><a name="Particulars">Particulars</a></h4>
<PRE>
   Given two state vectors s1 and s2 made up of position and
   velocity components (p1,v1) and (p2,v2) respectively,
   <b>dvdot_c</b> calculates the derivative of the dot product of p1 and p2,
   i.e. the time derivative

         d
         -- &lt; p1, p2 &gt; = &lt; v1, p2 &gt; + &lt; p1, v2 &gt;
         dt

   where &lt;,&gt; denotes the dot product operation.
</PRE>
<h4><a name="Examples">Examples</a></h4>
<PRE>
   Suppose that given two state vectors (s1 and s2)whose position
   components are unit vectors, and that we need to compute the
   rate of change of the angle between the two vectors.

   We know that the Cosine of the angle (theta) between the vectors is
   given by

      cosine(theta) = <a href="vdot_c.html">vdot_c</a>(s1,s2)

   Thus by the chain rule, the derivative of the angle is given
   by:

      sine(theta) dtheta/dt = <b>dvdot_c</b>(s1,s2)

   Thus for values of theta away from zero we can compute

   dtheta/dt as

   dtheta = <b>dvdot_c</b>(s1,s2) / sqrt ( 1 - <a href="vdot_c.html">vdot_c</a>(s1,s2)**2 )

   Note if the position components of s1 and s2 are parallel, the
   derivative of the  angle between the positions does not
   exist.  Any code that computes the derivative of the angle
   between two position vectors should account for the case
   when the position components are parallel.
</PRE>
<h4><a name="Restrictions">Restrictions</a></h4>
<PRE>
   The user is responsible for determining that the states s1 and
   s2 are not so large as to cause numeric overflow.  In most cases
   this won't present a problem.
</PRE>
<h4><a name="Literature_References">Literature_References</a></h4>
<PRE>
   None.
</PRE>
<h4><a name="Author_and_Institution">Author_and_Institution</a></h4>
<PRE>
   W.L. Taber      (JPL)
   E.D. Wright     (JPL)
</PRE>
<h4><a name="Version">Version</a></h4>
<PRE>
   -CSPICE Version 1.0.0, 7-JUL-1999
</PRE>
<h4><a name="Index_Entries">Index_Entries</a></h4>
<PRE>
   Compute the derivative of a dot product
</PRE>
<h4>Link to routine dvdot_c source file <a href='../../../src/cspice/dvdot_c.c'>dvdot_c.c</a> </h4>

      </td>
    </tr>
  </tbody>
</table>

   <pre>Wed Jun  9 13:05:21 2010</pre>

</body>
</html>

